<!doctype html>
<style>
a.test {
  font-weight: bold;
}
</style>

<html>
<head>
  <meta charset="utf-8">
  <title>Demo</title>
</head>
<body>
  <a href="http://jquery.com/">iQuery</a>
  <a href="http://baidu.com/">Baidu</a>
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
  <script>
    // my script code
    $(document).ready(function() {
      $("a").click(function() {
        $("a").addClass("test");
        alert("Thanks for visit jquery.com");
        event.preventDefault();
        $("a").removeClass("test");
        $(this).hide("slow", function() {
          alert("animation started! have fun!");
        });
      });
    });
  </script>
  <div id="clickme">Click here</div>
  <img id="book" src="book.png" alt="this is a book png" width="100" height="123"></img>
  <script>
    $("#clickme").click(function(){
      $("#book").hide("slow", function() {
        alert("animation started, have fun! :");
      });
      $("#clickme").hide();
    });
  </script>
</body>
</html>
